﻿using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace ITTestingSystem.Domain.Entities
{
    /// <summary>
    /// Specifies the description for the test
    /// </summary>
    /// 
    public class TestsDescription
    {
        /// <summary>
        /// Returns the unique identifier of the entity in the database
        /// </summary>
        /// 
        [Key]
        public int Id { get; set; }

        /// <summary>
        /// Returns the time for the tests completing
        /// </summary>
        /// 
        [Required]
        public int TimeLimit { get; set; }

        /// <summary>
        /// Returns the text of the description
        /// </summary>
        /// 
        [Required]
        public string Description { get; set; }

        /// <summary>
        /// Minimal score for the passing this test
        /// </summary>
        /// 
        [Required]
        public int MinimalScore { get; set; }




        /// <summary>
        /// Returns the topics that uses in the test
        /// </summary>
        /// 
        public virtual ICollection<TestsTopic> TopicsInTest { get; set; } 

        /// <summary>
        /// Returns the test that uses this description
        /// </summary>
        /// 
        [Required]
        public virtual Test Test { get; set; }
    }
}
